package com.ruoyi.app.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.app.mapper.AppUsersMapper;
import com.ruoyi.app.domain.AppUsers;
import com.ruoyi.app.service.IAppUsersService;

/**
 * 用户Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-11-04
 */
@Service
public class AppUsersServiceImpl implements IAppUsersService 
{
    @Autowired
    private AppUsersMapper appUsersMapper;

    /**
     * 查询用户
     * 
     * @param userId 用户主键
     * @return 用户
     */
    @Override
    public AppUsers selectAppUsersByUserId(Long userId)
    {
        return appUsersMapper.selectAppUsersByUserId(userId);
    }

    /**
     * 查询用户列表
     * 
     * @param appUsers 用户
     * @return 用户
     */
    @Override
    public List<AppUsers> selectAppUsersList(AppUsers appUsers)
    {
        return appUsersMapper.selectAppUsersList(appUsers);
    }

    /**
     * 新增用户
     * 
     * @param appUsers 用户
     * @return 结果
     */
    @Override
    public int insertAppUsers(AppUsers appUsers)
    {
        return appUsersMapper.insertAppUsers(appUsers);
    }

    /**
     * 修改用户
     * 
     * @param appUsers 用户
     * @return 结果
     */
    @Override
    public int updateAppUsers(AppUsers appUsers)
    {
        return appUsersMapper.updateAppUsers(appUsers);
    }

    /**
     * 批量删除用户
     * 
     * @param userIds 需要删除的用户主键
     * @return 结果
     */
    @Override
    public int deleteAppUsersByUserIds(Long[] userIds)
    {
        return appUsersMapper.deleteAppUsersByUserIds(userIds);
    }

    /**
     * 删除用户信息
     * 
     * @param userId 用户主键
     * @return 结果
     */
    @Override
    public int deleteAppUsersByUserId(Long userId)
    {
        return appUsersMapper.deleteAppUsersByUserId(userId);
    }
}
